﻿using Application.SaleReturn_dService;
using Domain.Entity.ord;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;

namespace WMSManage.Controllers
{
    [Route("api/[controller]/[action]")]
    [ApiController]
    [Authorize]//需要鉴权
    public class SaleReturn_dController : ControllerBase
    {
        private readonly ISaleReturn_dService saleReturn_DService;

        public SaleReturn_dController(ISaleReturn_dService saleReturn_DService)
        {
            this.saleReturn_DService = saleReturn_DService;
        }

        /// <summary>
        /// 根据销售退货id查询
        /// </summary>
        /// <param name="saletid"></param>
        /// <returns></returns>
        [HttpGet]
        public async Task<List<SaleReturn_d>> GetSaleReturn_Ds(int saletid)
        {
            return await saleReturn_DService.GetSaleReturn_Ds(saletid);
        }
    }
}
